package xyz.example.convert;

import org.junit.Test;
import xyz.lwm.lazycat.utility.convert.Convert;

import java.sql.Timestamp;
import java.util.Calendar;
import java.util.Date;

public class ConvertTest {

    @Test
    public void test() {
        Integer number = Convert.to("123", Integer.class);
        System.out.println(number);
        String str = Convert.toString(new Date());
        System.out.println(str);
        Timestamp timestamp = Convert.fromString(str, Timestamp.class);
        System.out.println(timestamp);
        Calendar calendar = Convert.to(new Date(), Calendar.class);
        System.out.println(calendar);
    }

}
